package main

import (
	"context"
	"fmt"
	bark "go_final/demos/grpc_validator/protofile"

	"google.golang.org/grpc"
)

func main() {
	conn, err := grpc.Dial(":8080", grpc.WithInsecure())
	if err != nil {
		panic(err)
	}
	defer conn.Close()

	c := bark.NewBarkClient(conn)

	res, err := c.SayHello(context.Background(), &bark.Person{
		Id: 8,
	})
	if err != nil {
		fmt.Println("err", err)
		return
	}
	fmt.Println("res", res)
}
